import { message } from 'ant-design-vue';
export default function (row: any, fetchUrl: any) {
    let statusColl = row.isCollected;
    fetchUrl(row.id)
        .then((res: any) => {
            console.log(res);
            statusColl = row.isCollected = !row.isCollected;
            message.success(statusColl ? '收藏成功！' : `已取消收藏！`);
        })
        .catch((err: any) => {
            console.log(err);
        });
}
